home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Greatest Childrens Stories Ever Told
/
Greatest_Stories.iso
/
demos
/
funtown
/
demo.dir
/
00046_Script_Scripts 1
< prev
next >
Wrap
Text File
|
1994-11-08
|
5KB
|
171 lines
--òòò Scripts 1
--ùùùùùùùùùùùùùùùùùùùùùùùùùùùùùù
on startMovieMacro backDrops
global mode, mode.1, HS, QL, MS
if HS then doMike
else
cursor 4
correctInterface
set QL=""
setGlobalVariables
setCurrentView
set the timeOutScript to "unloadCast"
if not ( mode ) then set mode=1
set mode.1= ( mode<>integer ( mode ))
set mode=integer ( mode )
initTracking
cursor -1
end if
end
--ùùùùùùùùùùùùùùùùùùùùùùùùùùùùùù
on setGlobalVariables
installMenu 0
global ML, WT, mode, MS, CV, WC, CIU, MIU, NM, M, H, V
set ML="Explore,Learn,Find,Match,Read,TreasureHunt,SuperTreasureHunt,What'sMissing,What'sDifferent,PictureDictionary"
set WT="0022c880,10334c81,200044c2,2330556c,c4400066,8c455077,88c66000,112c6770,12345678"
set MS=item (mode) of ML
set CV="0"
set WC=9000
set CIU=0
set MIU=0
set NM="0"
set M=the movie
set H=-18
set V=-13
end
--ùùùùùùùùùùùùùùùùùùùùùùùùùùùùùù
on setCurrentView
global CV, mode, MS
if the frame>=marker("map") then set CV="0"
else if the frame>=marker("posc1") then set CV="c"
else if the frame>=marker("pos81") then set CV="8"
else if the frame>=marker("pos71") then set CV="7"
else if the frame>=marker("pos61") then set CV="6"
else if the frame>=marker("pos51") then set CV="5"
else if the frame>=marker("pos41") then set CV="4"
else if the frame>=marker("pos31") then set CV="3"
else if the frame>=marker("pos21") then set CV="2"
else if the frame>=marker("pos11") then set CV="1"
else set CV = "0"
when keyDown then checkKeyEvent the key, charToNum ( the key )
randomizeQuestions 5
reposition (CV)
pointerCursor
end
--ùùùùùùùùùùùùùùùùùùùùùùùùùùùùùù
on checkKeyEvent whichKey, whichKeyCode
if the commandDown then exit
global mode, MS
if whichKey="?" or whichKey="/" then
doHelp
else if whichKeyCode=29 then
doArrow 4
else if whichKeyCode=28 then
doArrow 8
else if whichKeyCode=30 then
doArrow 2
else if whichKeyCode=31 then
doArrow 6
else if whichKeyCode=27 then
doBell
UnCoverDesktop
quit
else if whichKey="Q" then
if the commandDown then
doBell
UnCoverDesktop
quit
end if
else if whichKey="S" then
set the soundenabled=not ( the soundenabled )
else if whichKey>="0" and whichKey<="9" then
set the soundenabled=1
set the soundLevel=( value ( whichKey )) * 28
else if whichKeyCode=160 then
doTime
dontPassEvent
end if
end
--ùùùùùùùùùùùùùùùùùùùùùùùùùùùùùù
on UnCoverDesktop
global rwObj
if objectP( rwObj ) then rwObj( mDispose )
unload
end UnCoverDesktop
--ùùùùùùùùùùùùùùùùùùùùùùùùùùùùùù
on showTime
exitTracking
put the result
return the result
end
--ùùùùùùùùùùùùùùùùùùùùùùùùùùùùùù
on doTime manual
set filePath = "Around the House:Movies:Time Sounds:"
if length(string(manual)) then set theTime=manual
else set theTime=the time
set colon=offset (":",theTime)
set hour=value(char 1 to colon-1 of theTime)
if hour>12 then set hour=hour-12
set min=value(char colon+1 to colon+2 of theTime)
put hour && min
if min=0 then playTime filePath, hour& ",o'clock"
else if min=15 then playTime filePath, "quarter-past,"& hour
else if min=30 then playTime filePath, "half-past,"& hour
else if min=45 and hour<12 then playTime filePath, "quarter-of,"& hour+1
else if min=45 and hour=12 then playTime filePath, "quarter-of,"& 1
else
set whichSounds=hour& ","
if min<10 then set whichSounds=whichSounds& "0,"
if min<21 then set whichSounds=whichSounds& min
else
set tenMin=(min/10*10)
set whichSounds=whichSounds& string(tenMin)& ","
if not(min=tenMin) then set whichSounds=whichSounds& (min-tenMin)
end if
put whichsounds
playTime filePath, whichSounds
end if
end doTime
on loopsound
REPEAT WHILE SOUNDBUSY(1)
END REPEAT
EXIT
end
on playTime newPathName, whichSounds
repeat with x=1 to the number of items in whichSounds
put newpathname&(item x of whichsounds)
sound playFile 1, "Around the Town:Sounds:"&newName&value(item x of whichsounds)
updateStage
repeat while the soundBusy of 1
updateStage
end repeat
end repeat
end playTime
--ùùùùùùùùùùùùùùùùùùùùùùùùùùùùùù
on CorrectInterface
global mode, CV
if mode = 2 then exit
activate 48, the number of Cast "Skip",1,8,192,363,"","",""
updateStage
end
--ùùùùùùùùùùùùùùùùùùùùùùùùùùùùùù
on doMike
global mode, HS, DL, QL, QA, MS
cursor 4
set HS = false
if mode > 2 then activate 48, the number of Cast "Skip",1,8,192,363,"","",""
when keyDown then checkKeyEvent the key, charToNum ( the key )
reposition ( CV)
if mode = 2 then
puppetSprite 36, true
set the CastNum of Sprite 36 = the number of Cast MS
updateStage
end if
cursor -1
end